package com.common.retrofit.methods;

import com.common.retrofit.base.BaseMethods;
import com.common.retrofit.service.HaiNingService;

import rx.Observable;
import rx.Subscriber;

public class AlertBlackOrderMethods extends BaseMethods {

    private static AlertBlackOrderMethods m_ins = null;

    public static AlertBlackOrderMethods getInstance() {
        if (m_ins == null) {
            synchronized (AlertBlackOrderMethods.class) {
                if (m_ins == null) {
                    m_ins = new AlertBlackOrderMethods();
                }
            }
        }
        return m_ins;
    }

    @Override
    protected String getHttpUrl() {
        return "Friend/";
    }

    private HaiNingService initService() {
        return getRetrofit().create(HaiNingService.class);
    }


    public void cancel_follow(Subscriber<Object> subscriber,
                      int uid ,
                      String hashid  ,String bid ) {
        Observable observable = initService().cancel_blacklist(System.currentTimeMillis()+"",
                "7b788459fcadbf34bef91f20949ec3cb",uid,hashid,bid
        );
        toSubscribe(observable, subscriber);
    }
}
